#include <twi_plasmoid.h>

#include <QPainter>
#include <QFontMetrics>
#include <QSizeF>
#include <QGraphicsLinearLayout>

#include <plasma/theme.h>
#include <Plasma/LineEdit>
#include <Plasma/PushButton>
K_EXPORT_PLASMA_APPLET(twi, Twi)
Twi::Twi(QObject *parent, const QVariantList &args): Plasma::Applet(parent, args)
{
  setBackgroundHints(DefaultBackground);
  resize(200,200);
  
}

Twi::~Twi()
{
  if (hasFailedToLaunch()) {
    
  } else
  {
  }
}

void Twi::init()
{
  QGraphicsLinearLayout *layout = new QGraphicsLinearLayout(this);
  Plasma::LineEdit *m_lineEdit;
  Plasma::PushButton *m_pushButton;
  m_lineEdit=new Plasma::LineEdit(this);
  m_pushButton=new Plasma::PushButton(this);
  m_lineEdit->setText("Hello world");
  m_pushButton->setText("Press me");
  layout->addItem(m_lineEdit);
  layout->addItem(m_pushButton);
}


